/**
 * @projectName study-note
 * @package Mediator
 * @className Mediator.ConcreteMediator
 */
package Mediator;

import lombok.Data;

/**
 * ConcreteMediator
 * @description 具体的中介者
 * @author answer_wx
 * @date 2022/7/6 11:58
 * @version 1.0
 */
@Data
public class ConcreteMediator extends AbstractUN {

    private USA usa;
    private Iraq iraq;

    @Override
    public void forward(String message, AbstractCountry country) {
        if (country == usa) {
            iraq.getMessage(message);
        } else {
            usa.getMessage(message);
        }
    }
}